package edu.friday.service;

import edu.friday.common.result.TableDataInfo;
import edu.friday.model.SysRole;
import edu.friday.model.vo.SysRoleVO;
import org.springframework.data.domain.Pageable;

import java.util.List;
import java.util.Set;

public interface SysRoleService{
    List<SysRole> selectRoleAll();
    List<Long> selectRoleIdsByUserId(Long userId);

    TableDataInfo selectRoleList(SysRoleVO sysRoleVO, Pageable pageable);

    String checkRoleNameUnique(String roleName);

    boolean insertRole(SysRoleVO sysRoleVO);

    int deleteByRoleIds(Long[] roleIds);

    int updateRole(SysRoleVO sysRoleVO);

    void checkRoleAllowed(SysRoleVO sysRoleVO);
    int updateRoleStatus(SysRoleVO sysRoleVO);

    SysRole selectRoleById(Long roleId);
    Set<String> selectRolePermissionByUserId(Long userId);
}
